<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form"%>
<%@ taglib uri="http://tiles.apache.org/tags-tiles" prefix="tiles"%>

<div id="content" class="span10">
	<!-- content starts -->

	<div>
		<ul class="breadcrumb">
			<li><a href="#">Home</a> <span class="divider">/</span></li>
			<li><a href="#">Manage Users</a> <span class="divider">/</span></li>
			<li><a href="#">Roles List</a></li>
		</ul>
	</div>

	<div class="row-fluid sortable">
		<div class="box span12">
			<div class="box-header well" data-original-title>
				<h2>
					 Roles List
				</h2>
				<div class="box-icon">
					<a href="#" class="btn btn-minimize btn-round"><i
						class="icon-chevron-up"></i></a>
				</div>
			</div>
			<div class="box-content">
				
				<form:form id="modal-form" commandName="rolesDTO" action="rolesList" method="POST">
				<form:hidden path="empId" name="empId" value="${empId}" />
				<div class="control-group">
					<label class="control-label" for="radios"><strong>Person
							Roles</strong></label>
					<div class="controls">
						<c:set var="userRoles" value="${userRoles}" />
						<label class="radio inline" for="owner"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'owner')}">
									<form:checkbox path="owner" name="owner" id="owner" value="owner"
										checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="owner" name="owner" id="owner" value="owner" />
								</c:otherwise>
							</c:choose> Owner
						</label> <label class="radio inline" for="leadgenerator"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'leadgenerator')}">
									<form:checkbox path="leadgenerator" name="leadgenerator"
										id="leadgenerator" value="leadgenerator" checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="leadgenerator" name="leadgenerator"
										id="leadgenerator" value="leadgenerator" />
								</c:otherwise>
							</c:choose> Lead Generator
						</label> <label class="radio inline" for="salesmanager"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'salesmanager')}">
									<form:checkbox path="salesmanager" name="salesmanager"
										id="salesmanager" value="salesmanager" checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="salesmanager" name="salesmanager"
										id="salesmanager" value="salesmanager" />
								</c:otherwise>
							</c:choose> Sales Manager
						</label> <label class="radio inline" for="salesman"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'salesman')}">
									<form:checkbox path="salesman" name="salesman" id="salesman"
										value="salesman" checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="salesman" name="salesman" id="salesman"
										value="salesman" />
								</c:otherwise>
							</c:choose> SalesMan
						</label> <label class="radio inline" for="bussinessdeveloper"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'bussinessdeveloper')}">
									<form:checkbox path="bussinessdeveloper" name="bussinessdeveloper"
										id="bussinessdeveloper" value="bussinessdeveloper"
										checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="bussinessdeveloper" name="bussinessdeveloper"
										id="bussinessdeveloper" value="bussinessdeveloper" />
								</c:otherwise>
							</c:choose> Business Developer
						</label>
					</div>
				</div>
			
				<hr />
				<div class="control-group">
					<label class="control-label" for="radios"><strong>Leads</strong></label>
					<div class="controls">
						<label class="radio inline" for="leadAdd"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'leadAdd')}">
									<form:checkbox path="leadAdd" name="leadAdd" id="leadAdd"
										value="leadAdd" checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="leadAdd" name="leadAdd" id="leadAdd"
										value="leadAdd" />
								</c:otherwise>
							</c:choose> Add
						</label> <label class="radio inline" for="leadEdit"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'leadEdit')}">
									<form:checkbox path="leadEdit" name="leadEdit" id="leadEdit"
										value="leadEdit" checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="leadEdit" name="leadEdit" id="leadEdit"
										value="leadEdit" />
								</c:otherwise>
							</c:choose> Edit
						</label> <label class="radio inline" for="leadView"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'leadView')}">
									<form:checkbox path="leadView" name="leadView" id="leadView"
										value="leadView" checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="leadView" name="leadView" id="leadView"
										value="leadView" />
								</c:otherwise>
							</c:choose> View
						</label> <label class="radio inline" for="leadDelete"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'leadDelete')}">
									<form:checkbox path="leadDelete" name="leadDelete" id="leadDelete"
										value="leadDelete" checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="leadDelete" name="leadDelete" id="leadDelete"
										value="leadDelete" />
								</c:otherwise>
							</c:choose> Delete
						</label> <label class="radio inline" for="leadFollow"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'leadFellow')}">
									<form:checkbox path="leadFellow" name="leadFellow" id="leadFellow"
										value="leadFellow" checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="leadFellow" name="leadFellow" id="leadFellow"
										value="leadFellow" />
								</c:otherwise>
							</c:choose> Follow
						</label> <label class="radio inline" for="leadConvert"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'leadConvert')}">
									<form:checkbox path="leadConvert" name="leadConvert"
										id="leadConvert" value="leadConvert" checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="leadConvert" name="leadConvert"
										id="leadConvert" value="leadConvert" />
								</c:otherwise>
							</c:choose> Convert
						</label> <label class="radio inline" for="leadImport"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'leadImport')}">
									<form:checkbox path="leadImport" name="leadImport" id="leadImport"
										value="leadImport" checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="leadImport" name="leadImport" id="leadImport"
										value="leadImport" />
								</c:otherwise>
							</c:choose> Import
						</label>
					</div>
				</div>
			
				<hr />
				<div class="control-group">
					<label class="control-label" for="radios"><strong>Accounts</strong></label>
					<div class="controls">
						<label class="radio inline" for="accountAdd"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'accountAdd')}">
									<form:checkbox path="accountAdd" name="accountAdd" id="accountAdd"
										value="accountAdd" checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="accountAdd" name="accountAdd" id="accountAdd"
										value="accountAdd" />
								</c:otherwise>
							</c:choose> Add
						</label> <label class="radio inline" for="accountEdit"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'accountEdit')}">
									<form:checkbox path="accountEdit" name="accountEdit"
										id="accountEdit" value="accountEdit" checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="accountEdit" name="accountEdit"
										id="accountEdit" value="accountEdit" />
								</c:otherwise>
							</c:choose> Edit
						</label> <label class="radio inline" for="accountView"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'accountView')}">
									<form:checkbox path="accountView" name="accountView"
										id="accountView" value="accountView" checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="accountView" name="accountView"
										id="accountView" value="accountView" />
								</c:otherwise>
							</c:choose> View
						</label> <label class="radio inline" for="accountDelete"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'accountDelete')}">
									<form:checkbox path="accountDelete" name="accountDelete"
										id="accountDelete" value="accountDelete" checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="accountDelete" name="accountDelete"
										id="accountDelete" value="accountDelete" />
								</c:otherwise>
							</c:choose> Delete
						</label> <label class="radio inline" for="accountFollow"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'accountFellow')}">
									<form:checkbox path="accountFellow" name="accountFellow"
										id="accountFellow" value="accountFellow" checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="accountFellow" name="accountFellow"
										id="accountFellow" value="accountFellow" />
								</c:otherwise>
							</c:choose> Follow
						</label>
					</div>
				</div>
			
				<hr />
				<div class="control-group">
					<label class="control-label" for="radios"><strong>Contacts</strong></label>
					<div class="controls">
						<label class="radio inline" for="contactAdd"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'contactAdd')}">
									<form:checkbox path="contactAdd" name="contactAdd" id="contactAdd"
										value="contactAdd" checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="contactAdd" name="contactAdd" id="contactAdd"
										value="contactAdd" />
								</c:otherwise>
							</c:choose> Add
						</label> <label class="radio inline" for="contactEdit"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'contactEdit')}">
									<form:checkbox path="contactEdit" name="contactEdit"
										id="contactEdit" value="contactEdit" checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="contactEdit" name="contactEdit"
										id="contactEdit" value="contactEdit" />
								</c:otherwise>
							</c:choose> Edit
						</label> <label class="radio inline" for="contactView"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'contactView')}">
									<form:checkbox path="contactView" name="contactView"
										id="contactView" value="contactView" checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="contactView" name="contactView"
										id="contactView" value="contactView" />
								</c:otherwise>
							</c:choose> View
						</label> <label class="radio inline" for="contactDelete"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'contactDelete')}">
									<form:checkbox path="contactDelete" name="contactDelete"
										id="contactDelete" value="contactDelete" checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="contactDelete" name="contactDelete"
										id="contactDelete" value="contactDelete" />
								</c:otherwise>
							</c:choose> Delete
						</label> <label class="radio inline" for="contactFellow"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'contactFellow')}">
									<form:checkbox path="contactFellow" name="contactFellow"
										id="contactFellow" value="contactFellow" checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="contactFellow" name="contactFellow"
										id="contactFellow" value="contactFellow" />
								</c:otherwise>
							</c:choose> Follow
						</label>
					</div>
				</div>
			
				<hr />
				<div class="control-group">
					<label class="control-label" for="radios"><strong>Calls</strong></label>
					<div class="controls">
						<label class="radio inline" for="callAdd"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'callAdd')}">
									<form:checkbox path="callAdd" name="callAdd" id="callAdd"
										value="callAdd" checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="callAdd" name="callAdd" id="callAdd"
										value="callAdd" />
								</c:otherwise>
							</c:choose> Add
						</label> <label class="radio inline" for="callEdit"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'callEdit')}">
									<form:checkbox path="callEdit" name="callEdit" id="callEdit"
										value="callEdit" checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="callEdit" name="callEdit" id="callEdit"
										value="callEdit" />
								</c:otherwise>
							</c:choose> Edit
						</label> <label class="radio inline" for="callView"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'callView')}">
									<form:checkbox path="callView" name="callView" id="callView"
										value="callView" checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="callView" name="callView" id="callView"
										value="callView" />
								</c:otherwise>
							</c:choose> View
						</label>
					</div>
				</div>
			
				<hr />
				<div class="control-group">
					<label class="control-label" for="radios"><strong>Appointments</strong></label>
					<div class="controls">
						<label class="radio inline" for="appointmentAdd"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'appointmentAdd')}">
									<form:checkbox path="appointmentAdd" name="appointmentAdd"
										id="appointmentAdd" value="appointmentAdd" checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="appointmentAdd" name="appointmentAdd"
										id="appointmentAdd" value="appointmentAdd" />
								</c:otherwise>
							</c:choose> Add
						</label> <label class="radio inline" for="appointmentEdit"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'appointmentEdit')}">
									<form:checkbox path="appointmentEdit" name="appointmentEdit"
										id="appointmentEdit" value="appointmentEdit" checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="appointmentEdit" name="appointmentEdit"
										id="appointmentEdit" value="appointmentEdit" />
								</c:otherwise>
							</c:choose> Edit
						</label> <label class="radio inline" for="appointmentView"> <c:choose>
								<c:when test="${fn:contains(userRoles, 'appointmentView')}">
									<form:checkbox path="appointmentView" name="appointmentView"
										id="appointmentView" value="appointmentView" checked="checked" />
								</c:when>
								<c:otherwise>
									<form:checkbox path="appointmentView" name="appointmentView"
										id="appointmentView" value="appointmentView" />
								</c:otherwise>
							</c:choose> View
						</label>
					</div>
				</div>
				<div class="modal-footer">
					<button class="btn" data-dismiss="modal" aria-hidden="true"
						id="modal-form-submit">Cancel</button>
					<button class="btn btn-primary" type="submit">Save</button>
				</div>
			</form:form>
				
			</div>
		</div>
		<!--/span-->

	</div>
	<!--/row-->


	<!-- content ends -->
</div>
<!--/#content.span10-->
